import Vue from 'vue'
//vue-router@2.0版本的写法
import Router from 'vue-router'

import {getCookie} from '../utils/cookieUtil'

//使用路由组件
Vue.use(Router)
/*主页面的布局*/
//import Layout from '@/components/main-home'
// import MainHeader from '@/components/main-header'
// import MainHeaderSearch from '@/components/main-header-seacher'
// import MainContent from '@/components/main-content'
// import MainFooter from '@/components/main-footer'

//通用的样式
//import MainLoginHeadCommon from '@/components/views/common/main-login-head-common'

//登录
//import JobLogin from '@/components/views/login/job-login'
//import CompanyLogin from '@/components/views/login/company-login'

//注册
// import JobRegister from '@/components/views/register/job-register'
// import CompanyRegister from '@/components/views/register/company-register'

//底部版权信息
//import CopyRight from '@/components/views/common/footer-copyright-common'
//底部导航信息
//import FooterNav from '@/components/views/common/footer-nav-common'


//创建一个路由的实例 vue-router@2.0版本的写法
const router = new Router({
    routes:[
         {
          path: '/',
          redirect:'/home',
          component:()=>import("@/components/main-content")
        },
        {
            path:'/home',
            component:()=>import("@/components/main-home"),
            name:'home',
            children:[
                /*处理登录*/
                {
                    path:'loginJob',
                    component:()=>import("@/components/views/login/job-login"),
                    name:'loginJob'
                },
                {
                    path:'loginCompany',
                    component:()=>import("@/components/views/login/company-login"),
                    name: 'loginCompany'
                },
                /*处理注册*/
                {
                    path: 'registerJob',
                    component:()=>import("@/components/views/register/job-register"),
                    name: 'registerJob'
                },
                {
                    path:'registerCompany',
                    component:()=>import("@/components/views/register/company-register"),
                    name: 'registerCompany'
                },
                /*猎头招聘内容区域*/
                {
                    path:'headhuntingCompany/:typeId',
                    component:()=>import("@/components/views/recruitment/recruitment-content"),
                    name: 'headhuntingCompany',
                    children: [
                        {
                            path: 'recruimentHeadhunting/:id',
                            component:()=>import("@/components/views/recruitment/recruiment-headhunting"),
                            name: 'recruimentHeadhunting'
                        }
                    ]
                },
                /*企业招聘的内容的区域*/
              /*  {
                    path: 'companyRecruitment',
                    component:()=>import("@/components/views/recruitment/recruitment-content"),
                    name: 'companyRecruitment',
                    children: [
                        {
                            path: 'recruimentCompany/:id',
                            component:()=>import("@/components/views/recruitment/recruiment-company"),
                            name: 'recruimentCompany'
                        }
                    ]
                },*/


                /*猎头服务*/
                {
                    path: 'headhuntingService',
                    component:()=>import("@/components/views/headhuntingservice/headhuntingservice-content"),
                    name: 'headhuntingService',

                    children:[
                        {
                            path:'website/introduce',
                            component:()=>import("@/components/views/headhuntingservice/headhunting-website-introduce"),
                            name:'headhuntingWebsiteIntroduce'
                        },
                        {
                            path: 'website/huntingService',
                            component:()=>import("@/components/views/headhuntingservice/headhunting-website-service"),
                            name: 'headhuntingWebsiteService'
                        },
                        {
                            path: 'website/legalNotice',
                            component:()=>import("@/components/views/headhuntingservice/headhunting-website-law"),
                            name: 'headhuntingWebsiteLaw'
                        },
                        {
                            path: 'website/missionOfCompany',
                            component:()=>import("@/components/views/headhuntingservice/headhunting-website-mission-of-company"),
                            name: 'headhuntingWebsiteMissionOfCompany'
                        },
                        {
                            path: 'website/contact',
                            component:()=>import("@/components/views/headhuntingservice/headhunting-website-contact"),
                            name: 'headhuntingWebsiteContact'
                        },

                    ]


                },
                /*寻找猎头*/
                {
                    path:'searchHeadHunting',
                    component:()=>import("@/components/views/searchheadhunting/searchheadhunting-content"),
                    name: 'searchHeadHunting'
                },

                /*简历登记页面*/
                {
                  path: 'resumeRegister',
                  component:()=>import("@/components/views/resume/resume-register"),
                  name: 'resumeRegister'
                },
                /*简历预览页面*/
                {
                  path: 'pdfReview',
                  component:()=>import("@/components/views/resume/pdfReview/"),
                  name:'pdfReview'
                },

                /*职位发布页面*/
                // {
                //   path: 'jobPublish',
                //   component:()=>import("@/components/views/job/jobPublish"),
                //   name:'jobPublish'
                // },
                /*个人中心*/
                {
                    path:'personCenter',
                    component:()=>import("@/components/views/presonalCenter/person-center"),
                    name:'personCenter',
                    children:[
                        {
                            path:'myDeliverInfo',
                            component:()=>import("@/components/views/presonalCenter/jobperson/positionjobmanager/my-deliver-info"),
                            name: 'myDeliverInfo'
                        }
                    ]

                },
                {
                    path: 'companyCenter',
                    component:()=>import("@/components/views/presonalCenter/company-center"),
                    name: 'companyCenter',
                    children:[
                        /*个人信息*/
                        {
                          path: 'companyUserInfo',
                          component:() => import("@/components/views/presonalCenter/company/userInfomanager/company-user-info"),
                          name:'companyUserInfo'
                        },

                        /*企业管理*/
                        /*企业创建*/
                        {
                            path: 'companyCreateInfo',
                            component:()=>import("@/components/views/presonalCenter/company/companymanager/company-create-info"),
                            name:'companyCreateInfo'
                        },
                        {
                            path:'myPublishCompanyInfo',
                            component:()=>import("@/components/views/presonalCenter/company/companymanager/my-publish-company-info"),
                            name:'myPublishCompanyInfo'
                        },


                        /*职位管理*/
                        /*职位创建*/
                        {
                            path: 'workjobCreateInfo',
                            component:()=>import("@/components/views/presonalCenter/company/workjobmanager/workjob-create-info"),
                            name:'workjobCreateInfo'
                        },
                        {
                          path:'myPublishWorkJobInfoTwo',
                          component:()=>import("@/components/views/presonalCenter/company/workjobmanager/my-publish-workJob-info-two"),
                          name:'myPublishWorkJobInfoTwo'
                        },
                        /*职位审核信息*/
                        {
                            path: 'myPublishWorkjobInfo',
                            component:()=>import("@/components/views/presonalCenter/company/workjobmanager/my-publish-workjob-info"),
                            name:'myPublishWorkjobInfo'
                        },
                        /*我收到的投递*/
                        {
                            path:'myDeliveryCreateUserPosition',
                            component:()=>import("@/components/views/presonalCenter/company/workjobmanager/my-delivery-create-user-position"),
                            name:'myDeliveryCreateUserPosition'
                        }
                    ]
                }
            ]
        },
    ]
})


export default router

